//
//  WXPay.m
//  mall
//
//  Created by 一米阳光 on 15/8/2.
//  Copyright (c) 2015年 seekool. All rights reserved.
//

#import "WXPay.h"
#import "WXApi.h"


@implementation WXPay
+(void)WXPays
{
//    [[[LTClient sharedClient] paymentWithWeiXinPay:self.orderSN WithUid:[LTLoginService currentUid] ] subscribeNext:^(NSDictionary *dict) {
    //        NSLog(@"ret -> %@",dict);
    
    NSDictionary *dict ;
    
    PayReq* req             = [[PayReq alloc] init];
    req.openID              = [dict objectForKey:@"appid"];
    req.partnerId           = [dict objectForKey:@"partnerid"];
    req.prepayId            = [dict objectForKey:@"prepayid"];
    req.nonceStr            = [dict objectForKey:@"noncestr"];
    req.timeStamp           = [[dict objectForKey:@"timestamp"] intValue];
    req.package             = [dict objectForKey:@"package"];
    req.sign                = [dict objectForKey:@"app_sign"];
    NSLog(@"appid=%@\npartid=%@\nprepayid=%@\nnoncestr=%@\ntimestamp=%ld\npackage=%@\nsign=%@",req.openID,req.partnerId,req.prepayId,req.nonceStr,(long)req.timeStamp,req.package,req.sign );
    [WXApi sendReq:req];
//    }];
}
@end
